package com.icart.entities;

import javax.persistence.*;

@Entity
@Table(name = "bi_busitype", schema = "ams", catalog = "")
public class BiBusitypeEntity {
    private long busiid;
    private String businame;
    private Integer commuse;
    private Long chnid;
    private Integer status;

    @Id
    @Column(name = "busiid")
    public long getBusiid() {
        return busiid;
    }

    public void setBusiid(long busiid) {
        this.busiid = busiid;
    }

    @Basic
    @Column(name = "businame")
    public String getBusiname() {
        return businame;
    }

    public void setBusiname(String businame) {
        this.businame = businame;
    }

    @Basic
    @Column(name = "commuse")
    public Integer getCommuse() {
        return commuse;
    }

    public void setCommuse(Integer commuse) {
        this.commuse = commuse;
    }

    @Basic
    @Column(name = "chnid")
    public Long getChnid() {
        return chnid;
    }

    public void setChnid(Long chnid) {
        this.chnid = chnid;
    }

    @Basic
    @Column(name = "status")
    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        BiBusitypeEntity that = (BiBusitypeEntity) o;

        if (busiid != that.busiid) return false;
        if (businame != null ? !businame.equals(that.businame) : that.businame != null) return false;
        if (commuse != null ? !commuse.equals(that.commuse) : that.commuse != null) return false;
        if (chnid != null ? !chnid.equals(that.chnid) : that.chnid != null) return false;
        if (status != null ? !status.equals(that.status) : that.status != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = (int) (busiid ^ (busiid >>> 32));
        result = 31 * result + (businame != null ? businame.hashCode() : 0);
        result = 31 * result + (commuse != null ? commuse.hashCode() : 0);
        result = 31 * result + (chnid != null ? chnid.hashCode() : 0);
        result = 31 * result + (status != null ? status.hashCode() : 0);
        return result;
    }
}
